package com.example.shop.util;

/**
 * @BelongsProject: boot
 * @BelongsPackage: com.leisure.boot.util
 * @Author: 硕哥
 * @CreateTime: 2022-11-07  14:53
 * @Description: TODO
 * @Version: 1.0
 */

public enum  ResultCodeEnum {

    SUCCESS(200,"请求成功"),
    ERROR(444,"请求失败"),
    NETWORK_TIMEOUT(800,"请求超时"),
    FILE_OUT_MAX(801,"文件超出最大限制"),
    FILE_TYPE_ERROR(802,"文件类型不正确"),
    UNKNOWN_PAGE(404,"页面未找到");

    //状态码
    private final int code;

    //状态信息
    private final String msg;

    ResultCodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }
}
